package teste;

import javax.faces.application.FacesMessage;
import javax.faces.bean.ManagedBean;
import javax.faces.bean.RequestScoped;
import javax.faces.context.FacesContext;
import javax.servlet.http.HttpServletRequest;


@ManagedBean
@RequestScoped
public class Teste {

	public Teste() {
	}

	
	public String add(){
		FacesMessage facesMessage = new FacesMessage(FacesMessage.SEVERITY_INFO,"","Cadastro realizado com sucesso");
		FacesContext facesContext = FacesContext.getCurrentInstance();
		facesContext.addMessage("error", facesMessage);
		System.out.println("Add");
		return "";
	}
	
	
}
